package com.qyhl.module_practice.study;


import com.qyhl.webtv.commonlib.entity.news.SpecialDetailBean;
import com.qyhl.webtv.commonlib.entity.news.UnionBean;

import java.util.List;

public class PracticeStudyPresenter implements PracticeStudyContract.PracticeStudyPresenter {
    private PracticeStudyActivity mView;
    private PracticeStudyModel mModel;

    public PracticeStudyPresenter(PracticeStudyActivity mView) {
        this.mView = mView;
        this.mModel = new PracticeStudyModel(this);
    }

    @Override
    public void getSectionList(String sectionId, boolean isNew) {
        mModel.getSectionList(sectionId, isNew);
    }

    @Override
    public void getData(String sectionId) {
        mModel.getData(sectionId);
    }

    @Override
    public void setSection(List<UnionBean> beanList) {
        mView.setSection(beanList);
    }

    @Override
    public void setData(List<SpecialDetailBean> beanList) {
        mView.setData(beanList);
    }

    @Override
    public void setError(String msg) {
        mView.setError(msg);
    }
}
